docs(5956): add documentation to sentry usage#38644
Conversation
|
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
80c4ceb to
132655d
Compare
132655d to
4563265
Compare
Builds ready [4563265]
UI Startup Metrics (1252 ± 82 ms)
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
| | Environment | When Used | Build Command | Branch/Context | | ||
| | ------------------- | ---------------------------- | ----------------- | -------------------- | | ||
| | `production` | Production releases | `yarn build prod` | `stable` branch | | ||
| | `staging` | Main branch builds | `yarn build dist` | `main` branch | | ||
| | `development` | Local development | `yarn start` | Local dev server | | ||
| | `testing` | E2E test builds | `yarn build:test` | Any | | ||
| | `pull-request` | PR builds | `yarn build dist` | `pull_request` event | | ||
| | `release-candidate` | Release branches | `yarn build dist` | `release/*` branches | | ||
| | `other` | Fallback (should not happen) | - | Uncategorized | |
There was a problem hiding this comment.
Should we give the webpack commands too?
Builds ready [85f37a4]
UI Startup Metrics (1337 ± 110 ms)
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚀 Bundle size reduced!]
|
| ; The below is the `test-metamask` project. | ||
| ; SENTRY CONFIGURATION | ||
| ; SENTRY_DSN - For production builds only (do NOT use in development) | ||
| ; SENTRY_DSN_DEV - For local dev, CI/CD, and testing (sends to 'test-metamask' project) |
There was a problem hiding this comment.
Is this used by CI? I recall @HowardBraham was using this for performance testing at one point, I don't know if that's still the case.
There was a problem hiding this comment.
We may want to reconsider the decision to make the testing DSN publicly available given the amount of traffic it gets. We may also want to consider creating a separate project for CI than for testing/development.
When we first created test-metamask, it was easy to use because typically the person testing was the only one using the project at any given time, so errors were easy to detect.
Today given the volume and rate limiting, it's far more difficult to make use of.
If we created a new project just for one-off testing (for development or QA), and kept it secret, and avoided using it in CI, then we'd be back to the easy-to use experience we once had.
There was a problem hiding this comment.
Oh yes, we have a new just-for-CI one, it's called SENTRY_DSN_PERFORMANCE
There was a problem hiding this comment.
Included SENTRY_DSN_PERFORMANCE in 12c0844
Builds ready [594e3a8]
UI Startup Metrics (1296 ± 114 ms)
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Builds ready [de385bb]
UI Startup Metrics (1318 ± 112 ms)
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Builds ready [03d48ba]
UI Startup Metrics (1269 ± 101 ms)
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Builds ready [38b94cd]
UI Startup Metrics (1311 ± 99 ms)
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Description
The
test-metamaskSentry project receives significant traffic (284,823 events in 14 days), but there's no clear documentation on sentry setup and usage. This PR add some comprehensive documentation that developers can reference.Changelog
CHANGELOG entry: null
Related issues
Fixes: https://github.com/MetaMask/MetaMask-planning/issues/5956
Manual testing steps
Screenshots/Recordings
Before
After
Pre-merge author checklist
Pre-merge reviewer checklist
Note
Enhances Sentry documentation and configuration for developers.
development/README.mdwith Sentry overview, project/DSN mapping, environment matrix, environment and DSN selection logic (development/build/utils.js:getEnvironment,app/scripts/lib/setupSentry.js:getSentryTarget), common query examples, and local dev setup/testing steps.metamaskrc.distwith a dedicated Sentry section includingSENTRY_DSN,SENTRY_DSN_DEV(example), andSENTRY_DSN_PERFORMANCE, plus guidance to avoid using production DSN in dev/CIWritten by Cursor Bugbot for commit 38b94cd. This will update automatically on new commits. Configure here.